When making a web application, you're probably thinking if displaying data from Python to HTML is possible. The good news is that it is possible! The only library required for Python is called Jinja2. With Jinja2, you can render HTML files and place key values in the file. Here's an example:

templates/index.html:
<div class="container" id="container" style="text-align: center;color: white;">    {% if get_count %}
        <input type="checkbox" id="toggle-button" class="toggle-button" checked>
    {% else %}
        <input type="checkbox" id="toggle-button" class="toggle-button">
    {% endif %}

</div>

main.py:

@app.route('/')

async def main_page(request):

    return await render('moderation.html', context={'get_count': ...})