# Copy Button for Rich Text format output

**URL:** <https://community.weweb.io/t/copy-button-for-rich-text-format-output/7306>\
**Category:** How do I?\
**Created:** [February 27, 2024, 10:07pm UTC](https://community.weweb.io/t/copy-button-for-rich-text-format-output/7306 "2024-02-27T22:07:54Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![balekenyon](https://avatars.discourse-cdn.com/v4/letter/b/cdc98d/32.png) [@balekenyon](https://community.weweb.io/u/balekenyon)\
**Post date:** [February 27, 2024, 10:07pm UTC](https://community.weweb.io/t/copy-button-for-rich-text-format-output/7306/1 "2024-02-27T22:07:54Z")

</div>

Hello,

I’m outputting some formatted text to a rich text format box. Then I have a button using the “copy to clipboard” function in the workflow. This copies it as markdown. How would I go about making it copy rich text? Right now, I’m asking the user to copy and paste by selecting the text which works but not ideal in my case.

Thanks, community.

---

<div class="post-metadata">

**Author:** ![Joyce](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/joyce/32/13232_2.png) [@Joyce](https://community.weweb.io/u/Joyce)\
**Post date:** [February 29, 2024, 6:29pm UTC](https://community.weweb.io/t/copy-button-for-rich-text-format-output/7306/2 "2024-02-29T18:29:25Z")

</div>

Hi @balekenyon 👋

Mmm I don’t think there’s a simple solution for this right now 😕

When you bind the rich text input value, its format will be either markdown or html depending on what you defined as its output:

 ![CleanShot 2024-02-29 at 19.21.48@2x](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/a/ac281322adf9abf56baa7cfc4779b85a64489390.png)

There’s probably a way to “translate” that in a way that simply formats the text properly when the person pastes it but I’m not sure what that way would be…

Let me call the tech team to the rescue and get back to you on that one! 😅

---

<div class="post-metadata">

**Author:** ![raelyn](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/raelyn/32/2803_2.png) [@raelyn](https://community.weweb.io/u/raelyn)\
**Post date:** [March 13, 2024, 7:16am UTC](https://community.weweb.io/t/copy-button-for-rich-text-format-output/7306/3 "2024-03-13T07:16:47Z")

</div>

Hey Joyce! I am facing the same problem. How do we do this (copy rich text to clipboard)? Thanks!

---

<div class="post-metadata">

**Author:** ![emdiemeric](https://avatars.discourse-cdn.com/v4/letter/e/e9bcb4/32.png) [@emdiemeric](https://community.weweb.io/u/emdiemeric)\
**Post date:** [November 21, 2024, 2:35pm UTC](https://community.weweb.io/t/copy-button-for-rich-text-format-output/7306/4 "2024-11-21T14:35:18Z")

</div>

Hi, is there a solution to this? Looking for the same solution.

---

<div class="post-metadata">

**Author:** ![vfede](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/vfede/32/14020_2.png) [@vfede](https://community.weweb.io/u/vfede)\
**Post date:** [April 22, 2025, 10:35am UTC](https://community.weweb.io/t/copy-button-for-rich-text-format-output/7306/5 "2025-04-22T10:35:25Z")

</div>

I’m also looking to achieve this. I need to show the rich text but i also need to save it in plain text. i’m resorting to a long list of replace() right now.

---

<div class="post-metadata">

**Author:** ![mark](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/mark/32/4163_2.png) [@mark](https://community.weweb.io/u/mark)\
**Post date:** [April 22, 2025, 2:14pm UTC](https://community.weweb.io/t/copy-button-for-rich-text-format-output/7306/6 "2025-04-22T14:14:27Z")

</div>

I’m not sure if this helps, but here’s how I convert the html rich text to plain text, and it works perfectly for me. The only downside it if you have stuff thats bolded, it pasted as not bolded etc. But most copy to clipboard buttons act like that anyways.

In the workflow use the native “Copy to Clipboard” action.

Then in the field put the variable that holds the rich text followed by: .replace(/\<[^\>]\*\>/g, ‘’)

 ![Screenshot 2025-04-22 at 8.09.22 AM](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/2/25aaf9a5cab4b8e45f159e28e495c82fcaeebb4f.png)
