A cooling target, not a power meter
TDP stands for thermal design power. Intel's own wording is that it's the maximum power you should design the system for, a target that helps builders pick a cooler. It isn't a cap. Intel says a processor in turbo can exceed its TDP for a limited time, and from 12th Gen Core chips on, Intel calls the figure Processor Base Power.
AMD's number works the same way, and its own math shows the gap. AMD says the AM5 socket supports up to a 170 W TDP with a package power tracking (PPT) limit up to 230 W, and that PPT is TDP times 1.35 on Zen era sockets. The ratio of 230 W to 170 W is 1.35. In plain terms, a chip rated at 170 W can run at up to 230 W under load.
Sizing a cooler and a power supply
Cooler makers rate their coolers against TDP, which works for a chip that stays near its rating. For a chip allowed to draw more, look up the maker's maximum power figure (PPT on AMD) and size the cooler and the power supply from that. Add up the other parts and leave some room.
Don't compare TDP across brands. Each maker defines and measures it in its own way, so Intel and AMD ratings can't be compared accurately. Within one maker's lineup it's a fair guide to relative cooling needs.
TDP and the electric bill
TDP says nothing about what a chip costs to run. A processor that's idling or browsing draws far below its rating, and your bill follows the energy used, not the label. As an upper bound, a 125 W chip pinned at full load for 4 hours a day would use 183 kWh a year. At the site's $0.18 per kWh reference rate that's $32.85, and real use lands under it. A PC's draw also includes the graphics card, drives and fans, so estimate the whole machine with the Power Cost Estimator.