Data upload an transfer between tabs on Dash

Any help here would be greatly appreciated! I have the early stages of a Dash app that’s based on this structure from the Dash sample apps. Basically, I have an script that manages the app layout and the callbacks with a bit of it shown below:

app = dash.Dash(__name__, meta_tags=[{"name": "viewport", "content": "width=device-width"}],
server = app.server
UPLOAD_FOLDER_ROOT = <folder_path>
du.configure_upload(app, UPLOAD_FOLDER_ROOT, use_upload_id=True)

def live_layout():
    return html.Div([dcc.Location(id="url", refresh=False), html.Div(id="page-content")])

@app.callback(Output('upload-status', 'children'),
              Input('data-uploader', 'isCompleted'),
              State('data-uploader', 'fileNames'), )
def upload_status(iscompleted, filename):

@app.callback([Output('load-dataset', 'children'),
               Output('data-cols', 'options')],
              [Input('data-uploader', 'isCompleted'),
               Input('data-uploader', 'fileNames')],
              State('data-uploader', 'upload_id'))
def load_data(iscompleted, filename, upload_id):

@app.callback(Output("page-content", "children"), [Input("url", "pathname")])
def display_page(pathname):
    if pathname == "/data-cleaning/debugging":
        return debugging.create_layout(app)
    elif pathname == "/data-cleaning/errors-report":
        return errorsReport.create_layout(app)
    elif pathname == "/data-cleaning/solutions-report":
        return solutionsReport.create_layout(app)
    elif pathname == "/data-cleaning/cleaned-data":
        return cleanedData.create_layout(app)
    elif pathname == "/data-cleaning/supporting-documentation":
        return supportingDocumentation.create_layout(app)
        return overview.create_layout(app)

app.layout = live_layout
if __name__ == "__main__":

I have not included all the callbacks or the functions of them for brevity, but essentially, a user is allowed to upload a dataset using the dash_uploader function (more detail here) and then they click a button where scripts are used to clean the data for errors.

Each page (tab) usually starts with the following after importing the relevant libraries, where Header is a function to create a standardized page header:

def create_layout(app):
    # Page layouts
    return html.Div(
            # page 1

That’s the short of it, but basically, when transitioning from one tab to another, the data is cleared from memory and the user will have to start all over again. I have read many topics of dcc.Store and persistence but I really do not know how to go about implementing it based on the structure that I have. I would really appreciate any guidance as I am new to Dash.

Ideally, after the user uploads the dataset, I would like it to be in local memory and then be used by all the other callbacks, and not refresh the tabs every time a user navigates to another.

@chriddyp I know that you have been really helpful to others experiencing this issue and I have tried to implement your solutions into my situation but I can’t seem to get it right. Forgive my novice work with setting this up but I hope I structured the question well!