The adverb cap-a-pie (pie pronounced as the word pea) means (dressed, armed) from head to foot. It appeared as a military term in the 16th century.
It is first recorded in the 1523-25 translation of the French work Les Chroniques de Jean Froissart (circa 1337-1400), by Sir John Bourchier Lord Berners:
They helde themselfe styll in Parys, and provided for all thynges, as harnes and other abylments, as richely as though they had bene great lordes: and they were of harnessed men cape a pe, lyke men of armes, mo than xxx. thousande, and as many with malles.
The second earliest record of cap-a-pie is also in a military context. John Heywood wrote, in The Spider and the Flie (1556):
Ordnance of all sorts round the copweb was leyde,
And all spiders with all weapons, prest in eyde.
And to occupy all, spiders plaste aptlie.
Ech of them: harnest meete for his properte,
The rest, all in bright harnesse capape.
in Modern English:
Ordnance of all sorts round the cobweb was laid,
And all spiders with all weapons pressed in aid.
And to occupy all, spiders placed aptly,
Each of them harnessed meet for his property,
The rest all in bright harness cap-à-pie.
The English term seems to be a rendering of Middle French (de) cap à pié, (de) cap à pied. But this French form has never appeared in any French dictionary. Since the 14th century, these dictionaries have only recorded the French expression de pied en cap, literally from foot to head. It was originally used with armé, that is, armed.
In particular, the original French text by Jean Froissart is as follows:
Ils se tenoyent, dedans Paris, pourveus de toutes choses, & aussi d’armeures bonnes & riches (comme s’ils fussent grans Seigneurs) & se trouvoyent armés de pié en cap (comme droites Gens-d’armes) plus de trente mille, & plus de trente mille maillets.
However, de cap à pied did occur in French, albeit in a few texts. For example, a medieval account of Joan of Arc’s entry into Orléans on 29th April 1429 says that she was
armada de fer blanc tota de cap a pe (= dressed in a white iron-armour cap-a-pie).
On 14th July 1538, the king of France François 1er met the Holy Roman emperor Charles V at Aigues-Mortes, in Provence (south-east France). An account of this meeting says that
les mariniers estoient habillez de cap à pié de velours rouge (= the sailors were dressed cap-a-pie in red velvet).
And, in the essay titled Des armes des Parthes (Of the arms of the Parthians), the French philosopher Michel de Montaigne (1533-92) wrote that the Parthians
estoient armez de cap à pied, de grosses lames de fer, rengées de tel artifice, qu’à l’endroit des iointures des membres elles prestoient au mouuement.
were armed cap-a-pie with great plates of iron arranged in such a manner that in the parts of the limbs that require bending they lent themselves to the motion.
The first text was written at Albi, the second at Toulouse, and Montaigne was from the Bordeaux area. It is therefore possible that de cap à pied was peculiar to southern French and de pied en cap to northern French, which was the only variety of French that dictionaries recorded.