A method for Error Correction Code (ECC) encoding includes receiving data to be encoded. The data is encoded to produce a composite code word that includes multiple component code words. Each component code word in at least a subset of the component code words is encoded in accordance with a respective component code and has at least one respective bit in common with each of the other component code words.