They were admitted to hospital in December due to issues relating to heart disease but died on Saturday.
The twins were popular in Tanzania and the news has caused sadness nationwide.
Many people took to social media on Sunday to send messages of condolence to the family and friends.
Tanzanian President John Magufuli tweeted that he was “saddened” by their deaths, adding that Consolata and Maria had “dreamed of serving the nation”.
In an interview with the BBC last year, the twins said that after they had completed their university education, they wanted to become teachers.
“We will teach using a projector and computers,” they said.
People later remarked on their determination to acquire higher education qualifications regardless of a challenging system, which often found their condition hard to accommodate.
They were able to continue their studies as they grew older thanks in part to funding from local government and private donations.
Maria and Consolata, who were against the idea of being surgically separated, also told the BBC that they hoped to get married to one husband someday.
The two, whose parents died while they were still infants, were raised by the Catholic charity Maria Consolata, which had adopted and named them.
Last year, their high school graduation triggered a wave of congratulatory messages nationwide.
Professional freelancer and webmaster.