Topic: What is a documentation fee on a car, and where can I find if its legi

I found a great deal on a car at a local dealership. The only thing is, he says I need to pay an additional 'government mandated' documentation fee of $299. My cousin, who bought her vehicle from the same dealership doesn't remember paying such a fee, and I've never heard of this before. Isn't registration and titles for documentation? Where can I find government run websites to verify this is a legit fee? Thanks.