Corrosion activities and biofouling pose significant challenges for marine facilities, resulting in substantial economic losses. Inspired by the “brick&mortar” structure of pearls, a novel nanocomposite coating (Pun-HJTx) with long-lasting anticorrosion and intelligent antifouling modes is fabricated by integrating a compatible MoS2/MXene heterostructure as the “brick” into a polyurea-modified PDMS (Pun) acting as “mortar.” Notably, the presence of multiple hydrogen bonds within the coating effectively reduces the pinholes resulted from solution volatilizing. In the dark, where fouling adhesion and microbial corrosion activities are weakened, the MoS2/MXene plays a role in contact bactericidal action. Conversely, during daylight when fouling adhesion and microbial corrosion activities intensify, the coating releases reactive oxygen species (such as hydroxyl radicals and superoxide ions) to counteract fouling adhesion. Additionally, the coating exhibits multisource self-healing performance under heated or exposed to light (maximum self-healing rate can reach 99.46%) and proves efficient self-cleaning performance and adhesion strength (>2.0 Mpa), making it highly suitable for various practical marine applications. Furthermore, the outstanding performance of the Pun-HJT1 is maintained for ≈180 days in real-world marine conditions, which proving its practicality and feasibility in real shallow sea environments.