BHP bought back 8.3% of the issued capital of its Australian shares and 5% of its overall shares at a price of $27.64, a 14% discount to the market price.
The board has approved the payment of a US$1.02 per share special dividend.
The special dividend represents the residual $5.2 billion of net proceeds from the sale of BHP's onshore US assets.
"We are pleased to have completed the off-market buy-back which, together with the special dividend, will deliver on our commitment to return the net proceeds from the sale of our onshore US assets to our shareholders," BHP chief financial officer Peter Beaven said.
"Completion of this program will bring total cash returned to shareholders to $21 billion over the last two years."
Last week, Macquarie flagged the likelihood of further capital management.
"Assuming no further debt repayments, we believe BHP could return a further $3 billion in cash to shareholders in FY19, lifting total returns to $20 billion in FY19," it said.
Macquarie has an outperform rating and A$40 price target for BHP.
Shares in BHP rose 1.3% this morning to $32.83.