This is the first thing checked and the most common reason a straightforward tankless swap turns into a bigger project.
A tank water heater heats slowly and steadily — it has a whole tank of stored water and all day to bring it up to temperature. A tankless unit has to heat water instantly as it flows through, which means it demands substantially more gas at once. That demand often exceeds what the existing gas line to the water heater was sized to deliver.
The evaluation isn't just the line to the appliance, either. It's the meter capacity and the whole distribution — your furnace, range, dryer, and pool heater are all drawing from the same supply. Upsizing the line is routine work, but you want to know about it before you're committed, not after.