Floating upside down in the space station as she appeared on the screen before the Indian tricolour for a local TV show, Williams said, "I just want to wish everybody in India and people of Indian origin around the world a happy Diwali".
"It is a wonderful festival and I am happy we are part of it up here at the International Space Station," she said.
Williams, 47, spoke to Indian-origin student of New York University Riti Bhalla, who as a city-based TV host interviewed Williams on her Diwali special programme.
The tricolour was not the only Indian object accompanying Williams in space. She has also carried a picture of the Sanskrit word 'Om' and a copy of the Upanishads, which her father gave to her before she left for the space mission.
"I did bring a couple of things that have to do with India from my father, particularly a peaceful 'Om' that stays outside my crew quarters where I sleep and the Upanishads so I can read it while I am up here.
"It is a small version (of the Upanishads) but it definitely brings the wisdom to us while we are here and allows us to think of the true meaning of life and what we are doing. I have a couple of real true reminders of my Indian heritage while I am up here," Williams, dressed in a blue T-shirt and brown shorts, said.
Williams expressed appreciation for the support she has received from people in India and for their "heartfelt sincere feelings for the work we are doing up here and how we are doing and for our safe return back home".
As she waved goodbye and floated off, Williams said she hopes to visit India next Diwali "to say thank you to all the people in person".
The interview would be telecast in 75 countries on the occasion of Diwali. In August, the Indian-American astronaut had displayed the tricolour on board the International Space Station and wished Indians on the eve of their 66th Independence Day.
Williams along with Yuri Malenchenko of Russia and Japan's Akihiko Hoshide left for the ISS aboard a Russian spacecraft on July 15. She holds the record of the longest spaceflight (195 days) for a female space traveller.
Photos: These Indian cities top the list in online purchase of sex products
Photos: Varun Dhawan and Alia Bhatt at studio in Bandra
Photos: Katrina Kaif, Shamita Shetty at Mumbai airport
Photos: Varun Dhawan, Alia Bhatt promote 'Badri...' on 'Dil Hai Hindustani'
In pictures: 15 facts about kissing that will surprise you