Scrape as much of the rust off the nail as you can. Sandpaper will work best for the nail shaft. It can also work for the nail head, but a wire brush can work for that part also.

Or apply WD-40...