James Martin/CNET

WWDC 2020

Michelle Obama spoke at Apple's annual Worldwide Developers Conference in San Jose, California, on Tuesday, where she emphasized the importance of encouraging young girls to pursue careers in technology.

The former first lady, who launched an education initiative in 2015 called Let Girls Learn, said society has a long way to go when it comes to establishing equality and access in the workspace. The tech industry's lack of diversity continues to make headlines, with companies including Apple and Google undertaking efforts to hire and promote more women and minorities.

"It starts with education," Obama said. "And there's still millions of girls around the world who aren't getting an education, not just because of the lack of resources or not having access to schools ... there are cultural barriers that are keeping young girls down."

Obama's talk was closed to the press, but developers at WWDC posted video of the session online. She was joined onstage by Apple CEO Tim Cook and Lisa Jackson, the company's vice president of environment, policy and social initiatives and former EPA chief under the Obama administration.

A representative for Obama didn't immediately respond to a request for comment.

Obama said it's important to teach girls to value themselves and to let them know that they can compete in all kinds of settings.

Inspiring discussion at #WWDC17 with Michelle Obama and Lisa Jackson about diversity, being a role model and educating young girls. pic.twitter.com/x7c7oJ4DLJ — Caroline Jones (@carolinejonesYS) June 6, 2017

She added that the US is "not out of the clear," as it and other developed nations continue to grapple with issues such as wage inequality and birth control.

Because the audience was largely comprised of entrepreneurs, Obama reminded the crowd of the importance of female consumers.

"Women are in charge of everything," she said. "We buy everything. We make most decisions in the household. Who are you marketing to? Who do you think is going to use these apps?"

Obama also said it's crucial to promote racial diversity in the workplace.

She ended the talk by advising the audience to think about a "higher purpose," stating that the country needs problem solvers "who believe in the values and the diversity, who believe in the value of immigrants, who believe that global warming is real. We need people out there who are operating with a level of empathy.

"I hope that as you develop your app, yourselves and your business, you develop with an air of empathy and compassion, always thinking about, 'What more can I be doing for somebody else?'" she said. "If you do that, we'll be good."

Amazing talk from @MichelleObama Thank you for inspiring me to inspire others, starting from myself & finding a higher purpose #WWDC17 — Etash Kalra (@etash_kalra) June 6, 2017

Tech Enabled: CNET chronicles tech's role in providing new kinds of accessibility.

Batteries Not Included: The CNET team reminds us why tech is cool.