Can NFT metadata descriptions span multiple lines?

Hey everyone,

I’m working on NFT metadata and wondering if it’s possible to have a description that goes over multiple lines. Most examples I’ve seen only use one line for the description. Here’s a basic metadata structure I’ve been looking at:

{
  "metadataInfo": {
    "itemName": "string",
    "itemDescription": "string",
    "itemImage": "string"
  }
}

What I want to know is: can we make the itemDescription show up on different lines when viewed on platforms like OpenSea or Rarible? For example, could it look like this?

Line 1 of the description
Line 2 of the description
Line 3 of the description

Has anyone tried this before? How did it turn out? I’d really appreciate any insights or experiences you can share. Thanks!

yeah, you can totally do multi-line descriptions! just use ‘\n’ for line breaks in the JSON. most platforms support it. i’ve done it before and it looks great on opensea. gives you more flexibility to format your descriptions nicely. go for it!

hey SophiaAtom88, that’s a super interesting question! i’ve been playing around with nft metadata too and i was wondering the same thing :thinking:

have you tried using actual line breaks in your json instead of escape characters? something like this:

{
  \"metadataInfo\": {
    \"itemName\": \"Cool NFT\",
    \"itemDescription\": \"This is line 1\nThis is line 2\nAnd here's line 3!\",
    \"itemImage\": \"ipfs://...\"
  }
}

i’m not 100% sure, but i think some platforms might render it correctly this way. worth a shot, right? let us know how it goes if you try it out!

anyone else have experience with this? i’m really curious to hear more about different approaches :blush:

Indeed, multi-line descriptions in NFT metadata are feasible and widely supported. The key is to utilize the ‘\n’ escape sequence within your JSON structure to denote line breaks. This approach is compatible with major platforms like OpenSea and Rarible.

For implementation, simply incorporate the line breaks into your ‘itemDescription’ field:

{
  "metadataInfo": {
    "itemName": "string",
    "itemDescription": "Line 1 of the description\nLine 2 of the description\nLine 3 of the description",
    "itemImage": "string"
  }
}

This method allows for more structured and visually appealing descriptions, enhancing the overall presentation of your NFT metadata across various marketplaces and platforms.