Background color is checked just as strictly as photo size, and a shadow or the wrong shade is a common cause of rejection.
A plain, even background lets facial recognition software used by immigration systems isolate the face cleanly from the surroundings. Patterns, shadows or furniture in the background can interfere with this and lead to a photo being rejected even if the size is correct.
Plain white is the most common requirement, used by Pakistan, India, the USA, Canada, China, Japan, Singapore, Oman and many others. It gives the strongest contrast against most skin tones and hair colors.
The United Kingdom, Germany, Belgium and the Netherlands ask for a light grey background, and France and New Zealand do not accept pure white at all. Some other European countries, such as Italy, still use white, so always check your own country.
Light blue is rare for passports today. It is mostly seen on national ID cards, for example the Pakistan CNIC and NICOP use a light blue background, while the Pakistan passport uses white.
Achieving a clean, even background at home usually means standing against a plain wall in good light, then letting a tool apply the exact official background behind the cropped photo rather than trying to match the color with a physical backdrop. Uphoto applies the correct background automatically for the country you select.