The world-first law aims to address the media's loss of advertising revenue to US tech firms.
If passed, the law could have global consequences for tech firms and how we access news online.
But the tech firms have pushed back, with Facebook restricting news content in Australia.
So, what's the row all about?
There have long been concerns about the market dominance of tech firms over media organisations.
Google is the dominant search engine in Australia and has been described by the government as a near-essential utility, with little market competition.
And social media is a key source of news.
According to the Reuters Institute Digital News Report 2020, 52% of Australians questioned in a survey used social media as a source of news. Facebook ranked top as a social media news source, followed by YouTube and Facebook Messenger.
In 2018, an Australian government regulator launched an inquiry into the impact of Google and Facebook on competition in media and advertising.
Australia plans to make tech giants pay for news
The inquiry by the Australian Competition and Consumer Commission (ACCC) found an imbalance of power between tech firms and the media.
Given this, the regulator recommended introducing a code of conduct that it said would level the playing field.
In July last year, the Australian government unveiled a draft law to enforce the code, provoking threats from Facebook and Google to withdraw services in the country.
The draft calls on tech companies to pay for content, though it does not define what it is worth.
The law would enable news companies to negotiate as a bloc with tech firms for content which appears in their news feeds and search results.
If negotiations fail, the matter could be arbitrated by the Australian Communications and Media Authority.
Penalties could be up to A$10m (£5m; $7m) per breach, or 10% of the company's local turnover.
The government says the code will initially focus on Google and Facebook, but could be expanded to other tech companies.
The government has argued that tech giants should pay newsrooms a "fair" amount for their journalism.
In addition, it has argued that the financial support is needed for Australia's embattled news industry because a strong media is vital to democracy.
Media companies, including News Corp Australia, a unit of Rupert Murdoch's media empire, have lobbied hard for the government to force tech firms to the negotiating table amid a long-term decline in advertising revenue.
Facebook, however, argues "the value exchange between Facebook and publishers runs in favour of the publishers", according to its manager for Australia and New Zealand, William Easton, and generates hundreds of millions of dollars of revenue for the media.
"Publishers willingly choose to post news on Facebook, as it allows them to sell more subscriptions, grow their audiences and increase advertising revenue," he adds.
But Australia's competition watchdog - cited by the AFP news agency - says that for every $100 spent on online advertising, Google captures $53, Facebook takes $28 and the rest is shared among others, taking revenue away from media outlets.
Meanwhile, Google's revenues have increased markedly in the same period, amounting to more than $160bn (£117bn) globally in 2019.
Facebook has announced that it will block Australian users from sharing or viewing news.
The social media giant said the proposed law "fundamentally misunderstands the relationship between our platform and publishers".
Facebook said the legislation had left it "facing a stark choice: attempt to comply with a law that ignores the realities of this relationship, or stop allowing news content on our services in Australia".
"With a heavy heart, we are choosing the latter," it said.
Facebook imposed the ban with immediate effect, with users reporting that they were unable to see news articles on the platform.
Google has threatened to remove its search engine from Australia if the proposed law is passed.
But Google has now said it has agreed to pay Mr Murdoch's News Corp for content from news sites across its media empire.
News Corp said it would be sharing its stories in exchange for "significant payments".
As part of the three-year agreement, News Corp said it and Google would collaborate on a subscription platform, share advertising revenue and invest in video journalism on YouTube.
Google has also announced deals with several other Australian media companies, including a reported A$30m annual payment to Nine Entertainment.
It is not clear what action Google intends to take if the proposed law is passed.
Some Australian politicians and media experts think it could.
Australian Senator Rex Patrick has told Google: "It's going to go worldwide. Are you going to pull out of every market, are you?"
In contrast to Google and Facebook, Microsoft has thrown its support behind the proposed law.
"The code reasonably attempts to address the bargaining power imbalance between digital platforms and Australian news businesses," the software firm said in February.
There's also a different - but similar - row happening in Europe.
A controversial new EU rule on copyright says that search engines and news aggregators should pay news sites for links.
In France, publishers recently agreed a deal with Google on how that should work.
But only a handful of such deals have been signed with notable French newspapers - making it a very different thing than the wide-ranging, much stricter Australian plans.
And there have been other areas of tension between governments and big tech firms, where governments or blocs such as the EU have looked into regulating the firms in question.
The law has broad political support and has passed parliament's lower house.
If it gets through the Senate, the code is designed to be reviewed after a year.