1750, from French étiquette "prescribed behavior," from Old French estiquette "label, ticket" (see ticket (n.)).
The sense development in French perhaps is from small cards written or printed with instructions for how to behave properly at court (compare Italian etichetta, Spanish etiqueta), and/or from behavior instructions written on a soldier's billet for lodgings (the main sense of the Old French word).