California merchants may not ask customers who pay with credit cards for their ZIP codes, the California Supreme Court decided unanimously Thursday.

In a case closely watched by retailers, the state high court said ZIP codes were "personal identification information," which a state law bars businesses from demanding of customers.

The class-action lawsuit against Williams-Sonoma Stores Inc. was brought by a woman who contended that Williams-Sonoma asked her for her ZIP code when she purchased an item with her credit card. She said the store used her name and ZIP code to identify her address and then stored the information in a database for marketing. She also contended the store had the ability to sell her information to other businesses.

Two lower courts rejected the suit, but the California Supreme Court said a ZIP code was part of a person's address and therefore covered by the state's Credit Card Act.

"The Legislature intended to provide robust consumer protections by prohibiting retailers from soliciting and recording information about the cardholder that is unnecessary to the credit card transaction," Justice Carlos R. Moreno wrote for the court.

ALSO:

O.C. woman faked attack story

High school dean arrested in child pornography investigation

CHP in Orange County cracks down on drivers using cellphones

-- Maura Dolan