The Seattle City Council on Monday unanimously approved an ordinance that prohibits therapies that attempt to alter the sexual orientation or gender identity of LGBT youth.

The legislation is expected to take effect two months after Mayor Ed Murray signs it. Murray, who is openly gay, endorsed the measure.

Under the legislation, licensed mental health professional who provide so-called conversion therapy to minors will face civil penalties.

Seattle becomes the third city behind Cincinnati and Miami Beach to approve such legislation.

Six states – California, New York, New Jersey, Oregon, Illinois and Vermont – and the District of Columbia have approved similar bans. Similar bills were introduced in more than 20 states this year, according to the Human Rights Campaign (HRC), the nation's largest LGBT rights advocate.

Republicans officially oppose such measures. The Republican Party's platform, approved at the party's convention last month, supports the right of parents to seek such treatments for their children.

(Related: Chelsea Clinton blasts GOP platform's opposition to LGBT rights.)