New York Penal Law 140.17 – Criminal Trespass in the First Degree
Criminal trespass in the first degree is a felony offense in New York that involves unlawfully entering or remaining on someone else’s property while possessing a deadly weapon, explosives, or firearm. This article will explain the key elements of NY Penal Law 140.17, potential defenses, penalties, and related information in an easy-to-understand way.
What is Criminal Trespass in the First Degree?
Under New York Penal Law 140.17, a person commits criminal trespass in the first degree when they:
Need Help With Your Case?
Don't face criminal charges alone. Our experienced defense attorneys are ready to fight for your rights and freedom.
- 100% Confidential
- Response Within 1 Hour
- No Obligation Consultation
Or call us directly:
(212) 300-5196- Knowingly enter or remain unlawfully on someone else’s property
- While committing the trespass, they:
- Possess a deadly weapon, explosives, or firearm
- Know that another participant in the crime possesses a firearm
This charge is more serious than regular trespass because it involves the added element of a weapon, making the unlawful entry more dangerous.
Todd Spodek
Lead Attorney & Founder
Featured on Netflix's "Inventing Anna," Todd Spodek brings decades of high-stakes criminal defense experience. His aggressive approach has secured dismissals and acquittals in cases others deemed unwinnable.

You were exploring what you believed was an abandoned warehouse in Brooklyn when police arrived and discovered you were carrying a licensed firearm in your holster. You were arrested and charged with criminal trespass in the first degree under NY Penal Law 140.17, even though you had no intention of harming anyone.
Can I really be charged with a felony just for entering an empty building while carrying my legally owned firearm?
Under NY Penal Law 140.17, criminal trespass in the first degree is a Class D felony that applies when a person knowingly enters or remains unlawfully in a building and possesses a firearm, rifle, or shotgun — regardless of whether the weapon is legally owned or licensed. The prosecution does not need to prove you intended to use the weapon; merely possessing it while unlawfully present in the building satisfies the statute. A strong defense strategy may involve challenging whether you knowingly entered unlawfully — for example, if the building appeared abandoned with no posted signs or barriers, your attorney could argue you lacked the requisite intent. Given that a Class D felony carries up to seven years in prison, it is critical to retain experienced counsel who can evaluate whether the evidence supports each element of the charge.
This is general information only. Contact us for advice specific to your situation.
Elements of Criminal Trespass 1st Degree
To be convicted under NY Penal Law 140.17, the prosecution must prove these elements beyond a reasonable doubt:
- The defendant knowingly entered or remained unlawfully on the property or in the building of another person
- The defendant knew they did not have license or privilege to be on the property
- While committing the trespass, the defendant either:
- Possessed a deadly weapon, explosives, or firearm, OR
- Knew that another participant in the crime possessed a firearm
