Most of the money would come from the World Bank, which would provide 2 billion euros in finance, with France putting forward up to one billion euros and Germany just over 200 million euros, three sources said.
"Agreement on the amount and modalities has already been concluded and it's because of this that Turkey ratified the Paris accord," said one source who was aware of the talks.
Four sources said the full memorandum had yet to be agreed, and cautioned that nothing was certain until all parties had signed off. The sources spoke on condition of anonymity because of the sensitivity of the ongoing talks.
The European Bank for Reconstruction and Development (EBRD)and the International Finance Corporation, the private sector investment arm of the World Bank, are also involved to help drive the private sector role for green energy in Turkey.
The planned support for Turkey was reported by Politico last week, but the size and details of the loans have not previously been revealed.
Turkey's Environment Ministry did not immediately comment. A German government source, who could not confirm the 3.1 billion euro figure, said talks were continuing. "There is no MOU right now," the German source added.
A World Bank spokesperson did not comment on loan support, but said it welcomed Turkey's ratification of the accord and looked forward to more details of its plan to meet goals. "In this regard, we stand ready to scale up our support to Turkey through impactful projects," the spokesperson said.
RATIFICATION "AGAINST ALL ODDS"
Turkey signed the Paris agreement in April 2016 but had long resisted ratification, arguing that it should not be deemed a developed country for the purposes of the accord and was responsible for a very small share of historic carbon emissions.
Announcing Turkey's surprise change of heart last month, President Tayyip Erdogan told the United Nations General Assembly that countries that have a "historical responsibility" for climate change should make the most effort.
When it unanimously approved ratification on Oct 6, parliament said Turkey was doing so as a developing country, although the UN has not signalled any change.
The promise of funding could resolve that impasse.
France will provide several hundred million euros through its development agency AFD, a French diplomatic source said.
French President Emmanuel Macron has had troubled relations with Erdogan for years, but the two leaders have toned down their criticism in recent months.
A French government environment official said French and German environment ministers had discussed the issue in June, and that Turkey switched into a faster gear recently and ratified Paris "against all odds".
The Paris agreement aims to limit the global average temperature rise to well below 2 degrees Celsius above pre-industrial levels and make efforts to limit it to 1.5 degrees.
The 1.1-degree Celsius warming already recorded has been enough to unleash disastrous weather, including recent wildfires in Turkey, Greece and the United States.
Some of the worst wildfires in Turkey's history killed eight people and devastated tens of thousands of hectares of forest in the southwest this summer. The fires were followed closely by floods that killed at least 77 people in the north.
(Reporting by Jonathan Spicer in Ankara, Dominic Evans in Istanbul, John Irish and Elizabeth Pineau in Paris, Elizbeth Piper in London and Markus Wacket in Berlin; Editing by Gareth Jones) ((Dominic.J.Evans@Thomsonreuters.com, @DominicJEvans;))