Objects rolling around in panel above windshield


I have a 2006 BMW 325xi. The panel above the windshield (where the sun visors attach) has something inside rolling around. It sounds like multiple objects (a bunch of marbles or pebbles!) rolling around. I hear it when i turn a corner, sometimes when I hit a bump. If I flip the sun visor up abruptly I can hear something rattle. Any ideas?

It sounds like the headliner will need to be taken down to see what’s going on in there. You could take a powerful magnet and see if you can latch on to the objects if they are steel and move them elsewhere on the roofline where they don’t rattle so much, but I have doubts that this will work. Does the car have a sunroof?

Yes, there is a sunroof, although it opens and closes fine with no rattles. I looked in the area when the sunroof was open, but didn’t see anything loose.