A clean carpet begins with vacuuming regularly. That means more than just running a Hoover over the carpet once or twice a month. Use the crevice attachments to get dirt and dust from around the room. Vacuum the entire space horizontally, and then again vertically. The more times you run it over the surface, the more dirt it removes.
Don’t let the bag get more than half full or it won’t work as efficiently. It’s also not a race. Vacuum slowly so it has the chance to pick up all the dirt embedded below the surface to the carpet. Finally, adjust the height, so it works just right for your floor.