The inclusion-moderation hypothesis posits that including anti-system movements in political processes can moderate their political behaviour. While the literature concentrates primarily on analysing their ability to form alliances, bargain, compromise, and share power, little attention has been paid to how these movements adapt to changes in their political environment once they have entered institutional politics, and how they justify any shifts in their political behaviour to their constituencies in response. Combining key elements of the inclusion-moderation hypothesis with the Islamic principle of wasatiyyah (moderation), this article aims to address this lacuna. Using the Palestinian Islamist movement Hamas as a case study, this article analyses how Hamas adapted to the vicissitudes of its political environment after its 2006 election victory. Faced with a rapidly deteriorating political environment, the article demonstrates how Hamas responded by implementing a strategy that amplified its resistance credentials to provide it with a political bulwark. This allowed Hamas to modulate its positions on the two-state solution and its recognition of Israel. The article reveals how Hamas's bulwark strategy meant it could exhibit ideological flexibility, incrementalism, and compromise, while simultaneously placing caveats on these compromises to provide it with political room to manoeuvre. [ABSTRACT FROM AUTHOR]