Search History
Feature Overview
Implement a Search History & Suggestions feature within HungryHub’s search bar. This feature will:
- Retain users’ past search queries.
- Display real-time suggestions: recent searches, trending terms, and context-aware completions.
- Enable manual deletion of individual searches. Why now? This mirrors proven behaviors on TikTok and YouTube, improving search efficiency, UX familiarity, and trust.
Problem Statement
- Users don’t remember or cannot easily repeat prior searches (e.g., “menu for 2”, “sundae promos”).
- Privacy concerns: No ability to clear sensitive queries they may have made.
- Absence of trending or personalized suggestions hurts discovery and engagement.
Goals & Objectives
- User Efficiency: ≥ 40% of searches reused from history within 30 days.
- Engagement: Increase “search → restaurant page” conversions by +5%.
User Stories / Use Cases
Persona: Rina, casual diner
- As Rina, I want to revisit my “healthy bowls” search so I don’t type again. Persona: Adit, privacy-conscious user
- As Adit, I want to delete my “vegan specials” searches after I order to protect my data. Core Stories
- Remember my last 20 searches and surface 5 of them when I tap into search.
- Label suggestions (e.g., “Recent search”, “Trending this week”).
- Allow tap “x” to remove individual queries.
- Show trending searches (pulled from backend).
- Provide real-time typeahead suggestions from recent/trending sources.
Feature Scope
Must-Have
- Store last 20 search terms per user (local for guests, synced for logged-in).
- Clear labels: “Recent search”, “Just ordered”, “Trending”.
- Device sync across web/app sessions.
Should-Have
- Group by timeframe (“Today”, “This week”).
- Bulk “Clear all search history” for convenience.
Nice-to-Have
- Suggest based on order history (e.g., “You ordered sushi before—search again?”).
Design Considerations
- UI Layout:
- Suggestions appear beneath search bar, scrollable.
- Use icons: ⏱ for history, 🔥 for trending.
- Delete Action:
- tap “x” icon
- Visual Consistency:
- Integrate with the overall app theme (spacing, typography).
Measurement & Analytics (via GA4)
These metrics will be tracked using GA4 with event-based tracking
| KPI / Metric | GA4 Event or Report | Target |
|---|---|---|
| Search reuse rate | event: search_history_click | ≥ 40% of all search events |
| Conversion rate (search → order page) | measure: session_conversion_rate | +5% uplift via search |
| Delete interactions | event: search_history_delete | Track usage |
| Trending suggestion clicks | event: suggestion_trending_click | Track user engagement |
Route event tags via GTM with consistent naming (e.g., search_history_delete).
Technical Considerations
- Storage:
- Guests: local storage (cap at 20).
- Logged-in: store in backend + sync to device.
- Data sync:
- Pull history for logged-in; push deletes and new searches.
- Performance: lazy-load suggestions.