Allan Ramsay and his elder brother Robert probably attended the parish school at Crawfordjohn. In 1701 Allan was apprenticed to a wig-maker in Edinburgh and received his indentures back by 1709. He married Christian Ross in 1712; a few years after he had established himself as a wig-maker (not as a barber, as has been often said) in the High Street, and soon found himself in comfortable circumstances. They had six children. His eldest child was Allan Ramsay, the portrait painter.