In general, wildlife is facing increasing threats from rapid urbanisation in China. Ecological safety for wildlife requires an ecosystem that provides the conditions necessary for sustaining life. In this paper, two major breeding habitats and ten typical foraging habitats of egrets living in the urban environment were selected to assess the extent to which the needs of egrets can be satisfied and maintained. Ecological suitability and impacts from humans are the two major factors affecting egret ecological safety. An ecological indicator system was adopted to assess the ecological suitability of areas. Different land-use types were used to represent different degrees of human impact on the egret habitats, by employing a geographic information system. The results show that the two breeding habitats are at a safe level, while the ten foraging habitats are on the whole marginally safe. Full attention should be given to the conservation of wildlife foraging habitats in Xiamen Island.