Short answer: sometimes, but not always. In many cities, public trash cans are designed with a small built-in ashtray or cigarette disposal slot, especially on busy streets, near transit stops, or in parks. The idea is simple: if people have a safe place to put out and drop their cigarette butts, there is less litter and a lower fire risk.
That said, not every urban trash can comes with an ashtray attached. Some cities use separate smoking poles or wall-mounted cigarette receptacles instead. Others keep standard bins without any cigarette disposal feature, often because of maintenance costs, design standards, or local policies.
So if you are wondering about a specific city, it is best to check with the local public works department or parks agency. In general, though, attached ashtrays are common on modern city street furniture, but they are not universal.