1550s, "coarse fabric," of Scandinavian origin, cf. Norwegian dialectal rugga "coarse coverlet," from Old Norse rogg "shaggy tuft," from Proto-Germanic *rawwa-, perhaps related to rag (n.) and rough (adj.). Sense evolved to "coverlet, wrap" (1590s), then "mat for the floor" (1808). Meaning "toupee" is theater slang from 1940. Cut a rug "dance" is slang first attested 1942. To sweep (something) under the rug in the figurative sense is from 1954.
A toupee; hairpiece; divot: I even wear a little rug up front (1940s+ fr theater)
Related Termscut the rug, pull the rug out from under