Following the lead of progressive cities such as San Francisco, the San Jose City Council on Tuesday voted to ban city workers from traveling to North Carolina and Mississippi.

The San Jose City Council resolution bans all nonessential city travel and business to those two states, and also boycotts goods headquartered there until there's a change to "overturn existing discriminatory policies on sexual orientation.

Both southern states approved legislation preventing anti-discrimination protections for gay, lesbian and transgender people. North Carolina passed House Bill 2, or the "bathroom law," and Mississippi signed the "Protecting Freedom of Conscience from Government Discrimination Act."

Both "undermine the values of equality and diversity that we embrace in the city of San Jose," Mayor Sam Liccardo wrote to the council. Councilman Raul Peralaz said that it might not matter if just one city votes to ban travel, but as a "collective," states who have such laws will see that many entities are "standing up for human rights."

San Francisco already banned nonessential government travel to North Carolina in March, and then banned travel to Mississippi in early April.

Stars including Bruce Springsteen, the NBA, as well as companies like PayPal and jurisdictions including Atlanta, Boston, Washington, New York, Vermont, Connecticut and Minnesota have all enacted similar travel bans in the name of civil rights.

NBC Bay Area's Bob Redell contributed to this report.