Hewlett-Packard Co is recalling about 6 million computer power cords after 29 reports of the cords melting or charring, the U.S. Consumer Product Safety Commission said on Tuesday.

The recalled item, the LS-15 AC power cord, was distributed with Hewlett-Packard and Compaq notebook and mini notebook computers and with AC adapter-powered accessories such as docking stations, the commission said in a statement.

"Customers should immediately stop using and unplug the recalled power cords and contact Hewlett-Packard to order a free replacement," the statement said.

About 5.6 million power cords are being recalled in the United States, along with 446,700 in Canada. The cords were all made by a single, unidentified Chinese manufacturer, a source familiar with the situation said.

HP offered on Tuesday to replace all affected cords and apologized to customers.

The Palo Alto, California-based company has received 29 reports of cords overheating and melting or charring. There have been two claims of minor burns and 13 claims of minor property damage, the commission's statement said.

The computers and accessories were sold with the AC power cords at electronics stores, dealers and online from September 2010 through June 2012 for about $500 to $1,500, the statement said.