Four different amounts of anthracene groups were introduced into the polyimide (PI) backbone by one‐step polycondensation. This bulky and rigid polycyclic aromatic hydrocarbon structure effectively improved the solubility of the polyimide material. Therefore, the anthracene‐containing polyimides (ANPIs) were easily cast into the films at room temperature. The introduction of anthracene chromophores significantly developed the fluorescence performance of polyimides. It was found that the photoluminescence emission band of ANPIs migrated from the blue to the orange light region as the samples changed from solution to film. This is related to the aggregation of molecular chains in a solid state. Furthermore, ethanol and phenylethanol were selected to investigate the fluorescence response of the ANPI film. Interestingly, the sample displayed a noticeable luminescent “turn‐off” effect on the targets. It could be considered a convenient strategy for the detection of organic gases.