The pair were spotted carrying the air weapon by officers from South Yorkshire Police’s Off Road Team.
A spokesman said: “We happened across two lads in a nature reserve with an air rifle.
"We cant comment further as its a live investigation but fair to say you cant stroll about with a gun of any kind out in public like this.
"This one falls under trespass with an air weapon and can carry a hefty punishment, three months prison and £2,500 fine.
“Hope we saved the local wildlife in the nature reserve some pain and misery by seizing the gun.”
Anyone wanting to report crime can contact South Yorkshire Police on 999 in an emergency or 101 at other times or you can report information anonymously to CrimeStoppers on 0800 555 111.