A state becomes a party to a treaty through ratification, which signifies its consent to be bound by the treaty’s obligations, as per the Vienna Convention on the Law of Treaties (1969). Signing indicates intent, but ratification formalizes commitment. Thus, the correct answer is:
\[
{\text{Ratifying the treaty}}
\]