In this article we will explain how to add specified content at the end of the selected element in jQuery or What is append() method in jQuery or why use append() method in jQuery with example.


The jQuery append() method is used to add specified content end of  the selected element. If you want to add content at the beginning of the selected element, you should use jQuery prepend () method.



Let’s see, Example of jQuery append() method

<!DOCTYPE html>
    <title>Example of jQuery append method</title>
    <script type="text/javascript" src=""></script>
        $(document).ready(function () {
            $("#btntext").click(function () {
                $("p").append("<b>for beginners and experienced Developers.</b>.");
            $("#btnitem").click(function () {
    <p>This is a tutorial website.</p>
    <button id="btntext">Append text</button>
    <button id="btnitem">Append item</button>

 Let's check live example

Leave a comment

Make sure you enter the (*) required information where indicated. HTML code is not allowed.

You may also like