when two thirds of each House of Congress agree to do so
Vote of two thirds of both houses of Congress (House of Representatives and the Senate).
I think is when congress overturn a president veto
A bill, such as the cap and trade carbon bill, has to go through the House and Senate, before ending up on the Governors/Presidents desk, where he can sign it into law or veto it. The House and Senate can overturn a presidents veto with enough votes.
To overturn the president's veto of a bill 2/3rds of the congress needs to approve.
The veto.
VETO
Congress can pass a BILL over the President's veto making it a law.
If a US president vetoes a bill sent to him by the US Congress, the president may choose to veto the bill. In such a case, the bill is sent back to the congress. If the Congress can come up with a two thirds majority, then the bill must pass as law.
Congress can override the Presidents veto by a Supermajority Vote (2/3 of members)
A president's veto can be overridden by Congress with a 2/3 majority in the House. If it is a pocket veto though, the veto cannot be overridden.
This action is called an over-ride or over-riding of a veto.
Using the veto indicates that the President disagrees with Congress and that Congress was willing to pass a law they against the President's wishes.