The gap junction protein connexin43 (Cx43) binds to the second PDZ domain of Zonula occludens-1 (ZO-1) through its C-terminal tail, mediating the regulation of gap junction plaque size and dynamics. Biochemical study demonstrated that the very C-terminal 12 residues of Cx43 are necessary and sufficient for ZO-1 PDZ2 binding and phosphorylation at residues Ser (-9) and Ser (-10) of the peptide can disrupt the association. However, only a crystal structure of ZO-1 PDZ2 in complex with a shorter 9 aa peptide of connexin43 was solved experimentally. Here, the interactions between ZO-1 PDZ2 and the short, long and phosphorylated Cx43 peptides were studied using molecular dynamics (MD) simulations and free energy calculation. The short peptide bound to PDZ2 exhibits large structural variations, while the extension of three upstream residues stabilizes the peptide conformation and enhanced the interaction. Phosphorylation at Ser(-9) significantly weakens the binding and results in conformational flexibility of the peptide. Glu210 of ZO-1 PDZ2 was found to be a key regulatory point in Cx43 binding and phosphorylation induced dissociation.