One marine natural compound, anhydrofusarubin, was isolated from the endophytic fungus No. B77 from the mangrove tree on the South China Sea coast. It was the first time that such a compound was isolated from marine fungus. The structure was identified by NMR data and mass spectrometry (MS). In addition, its structure was determined by single-crystal X-ray diffraction analysis. It crystallizes in triclinic, space group P1 with a = 8.3185(15), b = 12.397(2), c = 13.767(3) , α = 65.692(3), β = 79.266(3), γ = 75.692(3)°, C15H12O6, Mr = 288.24, V = 1248.0(4) 3, Z = 4, Dc = 1.534 g/cm3, F(000) = 600, μ = 0.120 mm-1, the final R = 0.0459 and wR = 0.1184 for 5360 observed reflections (I > 2σ(I)). In the primary bioassay, the title compound shows strong inhibitory activity against Gram-positive bacteria Staphyococcus aureus (ATCC27154) with the MIC value of 12.5 μg/mL.