# Shorten URL

## Overview

The Labii Shorten URL feature allows you to generate short, trackable links to your records and data. Instead of sharing long, complex URLs, you can create simple shortened URLs that are easy to remember, share, and track. This feature is particularly useful for:

* **Easy Sharing**: Share concise links via email, messages, or presentations
* **Link Tracking**: Monitor how many times your shortened URLs have been accessed
* **Professional Appearance**: Present cleaner, more professional-looking links
* **Data Accessibility**: Direct people to specific records and forms without complex navigation
* **Workflow Integration**: Generate URLs dynamically using variables in forms and tables

## Accessing Shorten URL Feature

The Shorten URL feature can be accessed and created in multiple ways throughout Labii:

### From Share Table View

The Share table provides a dedicated interface for managing all your shortened URLs:

{% stepper %}
{% step %}
Navigate to the **Support** menu from the main navigation bar
{% endstep %}

{% step %}
Click on **Shorten URL** to access the Share table
{% endstep %}

{% step %}
View all your existing shortened URLs in the table with details like name, clicks, creator, and creation date
{% endstep %}
{% endstepper %}

### From Share Form View

When creating new shortened URLs or editing existing ones:

{% stepper %}
{% step %}
From the Share table, click the **+ ADD SHORTENURL** button
{% endstep %}

{% step %}
Fill in the form fields with your shortened URL details
{% endstep %}

{% step %}
Submit the form to create your shortened URL
{% endstep %}
{% endstepper %}

## Share Table Overview

The Share table displays all your shortened URLs with the following information:

* **Name**: Descriptive label for the shortened URL
* **Clicks**: Number of times the shortened URL has been accessed
* **Updated By**: User who last modified the shortened URL
* **Date Created**: When the shortened URL was created
* **Is Archived**: Whether the shortened URL is archived or active

<figure><img src="/files/qtPJjKD6tfCZovTUmw54" alt=""><figcaption><p>Share table showing all shortened URLs</p></figcaption></figure>

### Filtering and Searching

Use the search and filter capabilities to find specific shortened URLs:

* **Search Bar**: Type keywords or shortened URL names to quickly locate specific links
* **Active/Archived**: Filter by status to view only active or archived URLs
* **Date Range**: Filter by creation date or last modified date
* **Creator**: Filter by who created the shortened URL

## Creating a Shortened URL

### Using the Share Form

To create a new shortened URL:

{% stepper %}
{% step %}
**Access the Shortened URL Form**

1. Navigate to **Support** → **Shorten URL**
2. Click the **+ ADD SHORTENURL** button
3. The form opens with required and optional fields

<figure><img src="/files/wsAZ2OXtVJKAPjIl7v2D" alt=""><figcaption><p>Form for creating a new shortened URL</p></figcaption></figure>
{% endstep %}

{% step %}
**Fill in Required Fields**

**Name** (Required)

* Enter a descriptive label for the shortened URL (max 100 characters)
* Examples: "Lab Results July 2025", "Client Survey Form", "Project Dashboard"
* Make the name meaningful so you can easily identify the link later
* Use the **GENERATE** button for AI-assisted name suggestions

**Original Url** (Required)

* Paste the full destination URL that this short link will redirect to
* This can be:
  * A Labii record detail view URL
  * A form submission link
  * An external website URL
  * Any valid web address
* The full URL will be displayed in the shortened URL details for reference
  {% endstep %}

{% step %}
**Submit the Form**

1. Review the entered information for accuracy
2. Click the **SUBMIT** button to create your shortened URL
3. Your shortened URL will be generated and added to the Share table
4. You'll receive a shortened URL that you can immediately start sharing
   {% endstep %}
   {% endstepper %}

### Creating Shortened URLs in Share Form/View Context

When working with records in share form views, you can also create shortened URLs directly:

{% stepper %}
{% step %}
Open a record or data form that supports sharing
{% endstep %}

{% step %}
Click the **Share** or **Add Shortened URL** button (if available in your view)
{% endstep %}

{% step %}
The shortened URL creation form will appear with the current record URL pre-populated
{% endstep %}

{% step %}
Add a descriptive name for easy identification
{% endstep %}

{% step %}
Submit to create the shortened URL for quick sharing
{% endstep %}
{% endstepper %}

## Generating URLs with Variables

Labii supports dynamic URL generation within forms and table views using special variable syntax. You can automatically generate shortened URLs using the built-in variable function.

### Using SHORTENURL Variable

The `{{SHORTENURL:URL}}` variable allows you to dynamically create shortened URLs in your documents and forms:

**Syntax:**

```
{{SHORTENURL:URL}}
```

**How It Works:**

{% stepper %}
{% step %}
In any text field support variables (forms, widgets, etc.), use the variable syntax
{% endstep %}

{% step %}
Replace `URL` with the actual URL you want to shorten:

```
{{SHORTENURL:https://your-labii-instance.com/projects/123/records/456}}
```

{% endstep %}

{% step %}
The system automatically:

* Recognizes the SHORTENURL variable
* Generates a shortened URL for the provided link
* Displays the shortened URL in place of the variable
* Tracks clicks to the shortened URL
  {% endstep %}
  {% endstepper %}

**Variable Examples:**

* Static URL: `{{SHORTENURL:https://labii.com/documentation}}`
* Record Link: `{{SHORTENURL:https://your-instance.com/projects/lab-project/records/sample-001}}`
* Form Link: `{{SHORTENURL:https://your-instance.com/forms/data-entry-form}}`

**Use Cases for SHORTENURL Variable:**

* Automatically generate shortened links for record URLs in notifications
* Create compact links in email templates
* Generate trackable URLs in documents and reports
* Include shortened links in table cells or form fields
* Build dynamic sharing URLs that update as data changes

### Variable Integration in Contexts

**In Email Notifications:**

```
Check out this record: {{SHORTENURL:{{RECORD_URL}}}}
```

**In Document Templates:**

```
View full details: {{SHORTENURL:https://labii.com/projects/prj-001/records/rec-123}}
```

**In Table Cell Display:** Configure table columns to display shortened URLs dynamically for easy access to linked records.

## Managing Your Shortened URLs

### Viewing Shortened URL Details

<figure><img src="/files/H9dvvpAyrsRBmmIpqreE" alt=""><figcaption><p>Details view showing shortened URL information</p></figcaption></figure>

In the detail view of a shortened URL, you can see:

* **Original URL**: The full destination URL
* **Shortened URL**: The generated short link (clickable for copying)
* **Clicks**: Total number of times the URL has been accessed
* **QR Code**: Visual code for scanning and sharing (if available)
* **Created By**: User who created the shortened URL
* **Date Created**: When the shortened URL was created
* **Last Updated**: When the shortened URL was last modified

### Copying the Shortened URL

To share your shortened URL:

{% stepper %}
{% step %}
Open the shortened URL from the Share table
{% endstep %}

{% step %}
Locate the **Shortened Url** field in the detail view
{% endstep %}

{% step %}
Click the copy icon next to the shortened URL
{% endstep %}

{% step %}
The short link is copied to your clipboard
{% endstep %}

{% step %}
Paste the link in emails, messages, or anywhere you want to share it
{% endstep %}
{% endstepper %}

### Using QR Codes

If your shortened URL includes a QR code:

{% stepper %}
{% step %}
Open the shortened URL detail view
{% endstep %}

{% step %}
Locate the QR code in the **Shortened Url** section
{% endstep %}

{% step %}
Click **DOWNLOAD QR CODE** to save the QR code image
{% endstep %}

{% step %}
Include the QR code in printed documents, presentations, or materials
{% endstep %}

{% step %}
Users can scan the QR code with their phone camera or QR code reader to access the link
{% endstep %}
{% endstepper %}

### Editing Shortened URLs

To modify an existing shortened URL:

{% stepper %}
{% step %}
Navigate to the shortened URL in the Share table
{% endstep %}

{% step %}
Click the **EDIT** button in the detail view
{% endstep %}

{% step %}
Update the name or original URL as needed
{% endstep %}

{% step %}
Click **SAVE** to apply your changes
{% endstep %}

{% step %}
The shortened URL remains the same, but the destination URL can be updated to point to a new location
{% endstep %}
{% endstepper %}

### Tracking Click Analytics

Monitor the usage and reach of your shortened URLs:

* **Clicks Column**: See the total number of accesses directly in the Share table
* **Tracking Details**: View click counts in the detail view
* **Analytics**: Use click data to measure:
  * Link effectiveness in communications
  * Document sharing reach
  * User engagement with shared resources
  * Popular records and forms

## Archiving and Deleting Shortened URLs

### Archiving Shortened URLs

Archive shortened URLs you no longer actively use but want to keep for reference:

{% stepper %}
{% step %}
Select the shortened URL in the Share table
{% endstep %}

{% step %}
Change the **Is Archived** status to true
{% endstep %}

{% step %}
The shortened URL continues to work but is hidden from the active list
{% endstep %}

{% step %}
Use filters to view and restore archived URLs if needed
{% endstep %}
{% endstepper %}

### Deleting Shortened URLs

To permanently remove a shortened URL:

{% stepper %}
{% step %}
Select the shortened URL in the Share table
{% endstep %}

{% step %}
Click the **DELETE** button or icon
{% endstep %}

{% step %}
Confirm the deletion when prompted
{% endstep %}

{% step %}
The shortened URL is permanently removed and no longer accessible
{% endstep %}
{% endstepper %}

{% hint style="warning" %}
Deleting a shortened URL is permanent and cannot be undone. The short link will no longer work for anyone trying to access it. If you think you might need it again, consider archiving instead of deleting.
{% endhint %}

## Best Practices for Shortened URLs

### Naming Conventions

* Use descriptive, clear names that indicate what the link points to
* Include relevant dates if the link has time-sensitive content
* Avoid generic names like "Link 1" or "URL"
* Use consistent naming patterns across your organization

### Security Considerations

* Only shorten URLs that are appropriate to share publicly or with intended recipients
* Be aware that shortened URLs will track access and clicks
* Avoid shortening sensitive or confidential URLs
* Review who has access to your shortened URLs in the share table

### Effective Sharing

* Include context when sharing shortened URLs (explain what users will find)
* Use QR codes for print materials and presentations
* Include shortened URLs in email signatures for relevant resources
* Track click metrics to understand which links are most valuable

### Organization

* Use a consistent naming scheme for easy searching
* Archive outdated shortened URLs to keep your list clean
* Group related URLs by prefix or category in the name
* Regularly review and clean up unused shortened URLs

## Usage Examples

### Laboratory Sample Tracking

Create shortened URLs to reference samples across different systems:

```
Original: https://labii.com/projects/qc-analysis/records/sample-2025-001
Shortened: http://labii.io/s/abc123
Uses: Share sample details efficiently, track stakeholder access
```

### Form Distribution

Generate trackable links to data collection forms:

```
Original: https://labii.com/forms/experiment-results-form
Shortened: http://labii.io/s/xyz789
Uses: Email distribution, monitor form access, measure completion
```

### Document References

Link to standard operating procedures and documentation:

```
Original: https://labii.com/projects/documentation/records/sop-2025
Shortened: http://labii.io/s/def456
Uses: Include in lab notebooks, reference in emails, post in central areas
```

### External Collaboration

Share lab data with external partners:

```
Original: https://labii.com/projects/collaboration/records/project-data
Shortened: http://labii.io/s/ghi789
Uses: Partner access, track engagement, maintain security
```

## Troubleshooting

### Shortened URL Not Generating

If your shortened URL isn't being created:

* Verify the **Original URL** field contains a valid URL
* Ensure the URL is complete and properly formatted
* Check that you have permission to create shortened URLs
* Try clearing the form and re-entering the information

### Shortened URL Not Redirecting

If clicks on a shortened URL aren't working:

* Verify the original URL is still valid and accessible
* Check that the destination hasn't been moved or deleted
* Review user permissions to access the linked resource
* Edit the shortened URL to update the destination URL if needed

### Click Count Not Updating

If the click count appears stuck:

* The system may cache click data; wait a few moments and refresh
* Verify the shortened URL is being accessed by users
* Check that tracking is enabled for the shortened URL
* Contact support if the issue persists

## Best Practices for Link Longevity

* Regularly verify that shortened URLs still point to valid destinations
* Update destination URLs if content moves to a new location
* Archive personal or temporary shortened URLs after use
* Document important shortened URLs and their purposes
* Periodically review analytics to identify and remove unused links

The Labii Shorten URL feature provides a powerful way to create trackable, shareable links for your laboratory data and resources. Whether you're using the dedicated Share table, creating URLs directly from form views, or generating them dynamically with variables, shortened URLs streamline your data sharing and accessibility workflows.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.labii.com/support/shorten-url.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
