# How to represent text that must be isolated from its surrounding for bidirectional text formatting in HTML?

HTMLJavascriptProgramming Scripts

Use embed text with a different direction from another text, with the <bdi> tag, to represent isolated text.

## Example

You can try to run the following code to represent text to be isolated from its surrounding for bidirectional text formatting −

<!DOCTYPE html>
<html>
<title>HTML bdi Tag</title>
</html>