The maximum analog voltage you can give to your PIC (directly, without any divider) is 5V. So whatever analog signal you are trying to measure, make sure that the i/p volt to that pin should not exceed beyond 5V. If you want to measure voltage more than 5V, you should use resistor voltage divider network. The values of resistances required depends on the range of input voltage. For 5V your micro will produce 1024.
What does Vref- do?
Suppose in your experiment, if you are sure that your input analog signal will always between 2.5 -5V, then you can fix the Vref- to 2.5V , and use the entire 10-bit range to measure the voltage between 2.5 -5V. That means you will get reading 0 for i/p 2.5V, and 1024 for i/p 5V or more. This enhances the accuracy of analog measurements this way. Well, Vref+ will be at 5V in that case.
What does Vref- do?
Suppose in your experiment, if you are sure that your input analog signal will always between 2.5 -5V, then you can fix the Vref- to 2.5V , and use the entire 10-bit range to measure the voltage between 2.5 -5V. That means you will get reading 0 for i/p 2.5V, and 1024 for i/p 5V or more. This enhances the accuracy of analog measurements this way. Well, Vref+ will be at 5V in that case.