Oxides of iron and titanium are responsible for this.
Why does a magnet stick to granite.
Iron oxide is a fair permanent magnet ferrite magnets so if there is iron oxide in the granite it will be weakly magnetic unless the granite is laid on top of an fe containing material and your magnet is actually attracted to what is below.
If you bring rare earth magnet towards it the magnet attracts.
Especially if it is mined from india.
But heat up the right type of stone to just the right temperature and you could end up with a magnet scientists now report.
The most magnetic and common type is a lodestone.
Granite is intrusive which means that the magma was trapped deep in the crust and probably took a very long time to cool down enough to crystallize into solid rock.
This allows the minerals which form plenty of time to grow and results in a coarse textured rock in which individual mineral grains are easily visible.
Long before people invented the small magnets that stick to refrigerators or the big magnets that pick up cars at the junkyard people discovered natural magnets.
Granite can be slightly magnetic.