There had been concerns over the future of F1's first night race as the Singapore authorities and Ecclestone's Formula One Management organisation struggled to agree new terms.
The Marina Bay event appeared with a question mark on the provisional 2013 calendar this week as discussions continued.
But an agreement has now been reached to ensure that Singapore will stay on the schedule through 2017.
"All of us like being here, which is what made it difficult for us to negotiate," said Ecclestone. "We are here for another five years."
Singapore organisers said it has revised terms with FOM to secure a reduced fee.