The men, in their 40s and from south Wales, were reported missing around Dan-yr-Ogof and the Black Mountain just after 17:30 GMT on Saturday.
Dyfed-Powys Police said the pair were found just after midday on Sunday.
The men have been airlifted to hospital by helicopter to be assessed and treated, but police said their conditions were not life threatening.
Huw Jones, deputy team leader of Central Beacons Mountain Rescue Team, said: "The two men were experienced and well equipped and really did the right thing. When they became stuck they... called for help, then importantly they stayed put."
Also, two brothers from Pontypridd, Rhondda Cynon Taff, had a lucky escape when they were rescued from Scotland's Ben Nevis- the UK's highest mountain.
Rory Probert, 18, and Leon, 31, set off on their climb at about 11:00 on Saturday but by 14:00, a "white-out" brought heavy snow and blizzard-like conditions.
"We built a snow cave, but after lying there for five minutes we were freezing," said Rory Probert.
"We decided we had to make a push for the summit (where there is a cabin) or die trying."
Despite the conditions and "nearly walking off cliffs", they got there within a few hours, where they stayed before being rescued at 02:45 on Sunday by Lochaber Mountain Rescue.
However, in their struggle to reach the summit, they ditched their rucksacks- which included the keys to Leon Probert's truck.
After being rescued, they had to smash the window to get inside and they were still there waiting for the breakdown service to arrive on Sunday evening.
Two walkers who went missing on hills in the Brecon Beacons have been found.