An always on display method and an electronic device are provided. The method includes: An electronic device obtains text content. The electronic device performs word segmentation processing on the text content to obtain a plurality of word segments. The electronic device determines at least one layout format of the text content based on a quantity of words of the text content, a quantity of the plurality of word segments, and a preset mapping relationship. The at least one layout format includes a first layout format. The electronic device detects a screen lock operation. In response to the screen lock operation, the electronic device displays the text content on an always on display interface based on the first layout format.