mid-15c., "elegant, neat, trim," from Middle Dutch or Middle Low German dapper "bold, strong, sturdy," later "quick, nimble," from Proto-Germanic *dapraz (source also of Old High German tapfar "heavy," German tapfer "brave"), perhaps with ironical shift of meaning, from PIE root *dheb- "dense, firm, compressed."
Later shifting toward "small and active, nimble, brisk, lively" (from c. 1600). "Formerly appreciative; now more or less depreciative, with associations of littleness or pettyness" [OED].