1 Kings 4:26 (NKJV)
Solomon had forty thousand stalls of horses for his chariots, and twelve thousand horsemen
2 Chronicles 9:25
Solomon had four thousand stalls for horses and chariots, and twelve thousand horses, which he kept in the chariot cities and also with him in Jerusalem.
This is a copyist error (see the translation footnotes). The general consensus is that 4000 is the correct number, since it's closer to the number of horsemen.
Other responses (offsite)