Mrs. Trump came up with the logo and program name herself, her aides said.

Observers on social media seized on the event, noting that the link the White House sent out for the “Be Best” website initially delivered an error message, and that Mrs. Obama, Mrs. Trump’s immediate predecessor, had delivered a speech last year urging men to “be better.” During the 2016 campaign, Mrs. Trump took flack for a speech that appeared to be sourced, in part, from remarks Mrs. Obama made in 2008.

Initially, Mrs. Trump had backed away from her original promise to combat cyberbullying after the criticism leveled at Mr. Trump for his online insults. Knowing she would get criticized if she pursued anything related to social media, Mr. Trump suggested she take an easier path. But Mrs. Trump ultimately decided to make good online behavior a part of something broader, an East Wing official said.

Mr. Trump appeared pleased. “That was truly a beautiful and heartfelt speech,” he said in remarks in the Rose Garden after Mrs. Trump spoke. “It’s the way she feels, very strongly. America is truly blessed to have a first lady who is so devoted to our country.”

In her brief time at the White House — Mrs. Trump moved to Washington with her son, Barron, last June — she took her time establishing her own profile, with only a stilettoed misstep or two, literally: She piqued the public’s interest by wearing high heels on a trip to Texas after it was hit by Hurricane Harvey. She also drew positive attention for speaking against the racial violence in Charlottesville, Va., that left one woman dead.

In January, after news broke that Stephanie Clifford, the pornographic film actress known as Stormy Daniels, was paid $130,000 before the 2016 election to keep quiet about a sexual encounter with Mr. Trump, Mrs. Trump cut back her public appearances. Her office dismissed her absence as a coincidence, while others close to the president said that Mrs. Trump had been angered by the news reports.

In recent months, Mrs. Trump has emerged more often without Mr. Trump by her side, although she has twice been seen avoiding or swatting the president’s hand away during public appearances. She is rolling out her platform even as Mr. Trump and his legal team have added new, confusing contours to the story surrounding Ms. Clifford.

If Mrs. Trump remains something of an enigma to most Americans, there is at least some evidence that the public has warmed to the wife of a president whose popularity remains at historic lows. In a CNN poll conducted May 2 to May 5, 57 percent of respondents said they held a favorable view of Mrs. Trump — up 10 percentage points from January — while 27 percent had a negative view.