Magnetic fluid is a new functional material for optical sensors. The microstructure will be changed with various applied magnetic fields. In this paper, the molecular dynamics method based on rod-like particle was first used to simulate the microscopic movements of magnetic nanoparticles in magnetic fluid with the volume fraction of 1%. Simulation results showed that magnetic nanoparticles could aggregate to form a new type of magnetic fluid photonic crystal when the applied magnetic field intensity exceeded 180 Oe. Then, the tunability of the magnetic fluid photonic crystal was studied. It was found that the average diameter of magnetic columns would decrease when the applied magnetic field intensity was increased from 180 to 320 Oe. Furthermore, based on the simulation results, optical property of the magnetic fluid photonic crystal was studied. When the direction of the incident light was parallel to the direction of the applied magnetic field, the transmissivity would increase from 0.5944 to 0.6475, whereas when the direction of the incident light was perpendicular to the direction of the applied magnetic field, the two photonic bandgaps of transverse electric mode and TM mode all moved to higher frequency, and the two bandwidths decreased about 17% and 87%, respectively. Through the above research studies, it was proved that the magnetic fluid photonic crystal processed the magnetic tunability and would be used as a novel magnetic field sensor in the future.