Hood ? nests from squirrels

how do you keep critters away under the hood as in squirrels nest ?

Drive it more often.

If that’s not an option, throw mothballs under the hood. Be sure to remove them before you start it again.

been using mothballs

Live trap them and relocate at least one mile from house. remove whatever they are feeding on around the house. eventually you will either trap them all or they will look for food elsewhere.

Try spraying some coyote urine (used for deer repellent). Don’t know for a fact, but I’m guessing squirrels don’t mess with coyotes.