The new legislation, passed by 43 votes to 42, was one of several conditions by the IMF for revival of a stalled $6 billion funding programme. The lower house had passed the law earlier this month.
The bill gives the bank independent powers to control price stability and monetary policy decisions, plus guaranteed tenure for its governor.
It also stops the government from borrowing from the bank.
The IMF review board is next meeting on Feb. 2 to discuss a pending tranche of $1 billion.
To meet its conditions, Pakistan has also passed a mid-year budget to end exemptions on sales tax as part of fiscal tightening to raise 343 billion rupees ($1.93 billion) for the 2021-22 financial year.
Foreign inflows are critical to Pakistan’s economy given that its external account deficit has widened on the back of soaring global commodity prices, particularly oil which makes up about a third of the country’s payments.
Foreign exchange reserves are also a key buffer to stabilise the rupee. Pakistan only last year adopted a market-based exchange rate, resulting in a sharp depreciation of the rupee.
Pakistan earlier this week raised $1 billion with a 7-year sukuk, offering an interest rate of 7.95%, the highest return the South Asian nation has ever paid on an Islamic bond.