The present disclosure is directed to an endoscopic surgical stapler having an articulation locking mechanism that functions to prevent straightening of a tool assembly of the surgical stapler when the surgical stapler is fired with the tool assembly in an articulated position. In embodiments, a mounting assembly supports a notched member on a proximal end of the tool assembly and the notched member defines a series of notches. An articulation member supported adjacent to the mounting assembly includes a locking member defining protrusions or teeth that are movable from a first unlocked position spaced from the notches of the mounting assembly to a second locked position received within the notches to lock the tool assembly in one of a plurality of articulated positions. In embodiments, the locking member is biased towards the unlocked position by a biasing member and is urged toward and retained in the locked position via engagement with a drive assembly of the surgical stapler.