These two words are pronounced in the same way – /dɪə(r)/, but other than that, they are two completely different words. They are spelt differently and have different meanings.
A DEAR friend is a friend you love very much.
A DEER is an animal with antlers on its head, usually found in forests (see picture). Grammatically speaking, the interesting thing about this word is that ‘deer’ is both singular and plural form (there is no -s in the plural).