This is not possible with the WP_Query. You can specify relationship inside the tax query and inside the meta query, but, you can’t have the query where meta and tax query are connected by OR.
You can always build the SQL query the way you want it, not relying on the WP_Query at all to filter posts exactly the way you want it. Or, you can use two WP_Query objects, one with meta_query, other with tax_query, and merge the results. In case you have a lot of posts, or you need pagination, that will be a challenge to make optimized.
Related Posts:
- Nested meta_query with multiple relation keys
- Does tax_query really beats meta_query in all situations?
- WooCommerce: filter by parent product’s taxonomy and product variation’s meta data
- Querying by taxonomy vs Querying by Custom fields Speed Comparison
- Tax query clause inside a meta query clause?
- Is it a good idea to improve meta query performance by adding tax query?
- Tax query AND/OR meta query [duplicate]
- Query with meta_query and tax_query together not working properly
- How to search for meta_query LIKE or tax_query LIKE and grab these posts on search results?
- WP_Query for a taxonomy value OR a custom post type meta field
- Extending WP Query: Custom geolocation meta values work, but tax_query breaks
- Custom query with custom filtering returning incorrect results
- WP Query Args – Title or Meta Value
- Meta query with string starting like pattern
- Query WooCommerce orders where meta data does not exist
- Execute a large WP_Query with many “AND” Meta_Queries?
- Query all posts where meta value is empty
- WP_Query min and max values
- querying with custom meta field with meta_query
- Order by two meta keys
- multiple meta key but get server load is very high
- A WP_Query that will look for posts after 2 weeks ago OR with a certain meta value
- Finding all results from database within 500 miles of the given latitude and longitude [closed]
- if wp_query taxonomy term have posts
- Combine tax_query and meta_query in WP_Query
- Get term by custom term meta and taxonomy
- Use meta_query to display events by date in custom field
- Meta-value query
- Meta query field order together with post_date order causes posts without the meta field to be unordered
- tax_query OR with empty result returns all posts
- pre_get_posts filter meta_query without conflicting existing meta_query
- Undefined property: WP_Query::$post
- Programmatically set ‘meta_query’ for filter
- Get list of terms that have posts in another term
- WP_Query meta_query >= date
- Extending woocommerce admin product search
- Complex Orderby Parameters: How to query with multiple orderby parameters using meta_value_num?
- Adding an array from a query string to a WP meta_query
- Query multiple meta values
- Optional Meta Query
- Query by multiple meta elements not seeming to work – wordpress is timing out
- Fetch posts that match term slug first two letters (wp query)
- WP_Query tax query part of slug
- Meta_query on same meta key, with diffrenct values
- Can we return all category (not post) with Custom Query Filter? [closed]
- How does one perform a sub query with different post types
- how to make members list directory through wordpress post custom meta key.
- WP_Query with meta_query dosen’t return results
- meta_compare not comparing whole integer
- meta queries do ‘either/or’ checks
- WP Query ordering on a meta field for posts with a date in the future not ordering by datetime
- Selecting posts with a given meta value for a meta key
- Get every post with value in meta key
- get_page meta query not working, maybe a bug?
- Show single posts date, in a page of posts
- WP_Query Class custom field parameters
- WP_Query not returning correct result with meta_query parameter
- meta_query where the meta value is not the post title
- Order WP_Query by meta_key priority when ‘OR’ relation used for multiple meta values
- Facing problem with tax_query results
- How do i create a custom post query when the meta value is an array?
- meta_query with meta values as serialize arrays
- Woocommerce Get Orders By Meta Value
- meta_query is overriding default search
- Multiple WP_Query args combinations according to post type
- WP_Query multiple value not working
- How to do WP_User_Query for Nested Array value Inside Nested Array field
- Custom query to retrieve oldest post and retrieve others with date interval
- WP_User_Query Orderby Not Working
- Unusual high query of user meta data
- Very slow query generated getting meta data from posts
- WordPress post_status and meta_query
- WordPress Query optimaization for slow query
- How to filter on placeholder image
- Tax_Query not working – connecting to second wordpress database
- Slow wp_posts and wp_postmeta query using Advance Custom Fields
- Meta query doesn’t remove placeholder escape before query
- WP Query Meta Query
- in tax_query this Is the code correct? I need to access beginner video posts for different subject
- Query custom meta value – post view and date meta
- How can I modify standard search query to include also ACF custom fields values?
- Custom WP_query and integrating into theme file
- WP_Query – show posts where meta value and user_email match
- Custom taxonomy and query multi conditions
- Best way to Order Post in Home without a plugin
- Empty ‘terms’ in ‘tax_query’ returns an empty array
- WP_Query: Meta_Query with serialized value (or a workaround)
- WP_Query using meta_query with LIKE doesn’t return what it should
- Return a single custom post from multiple meta queries
- query post based on comparison
- Including ‘cat’ => $cat breaks meta_query
- Query string form $_GET[‘value’] is not working as meta value in wp_query
- Can’t figure out query logic
- WP_Query orderby not working on custom post_type
- 294 Queries on Mainpage of WordPress
- WP_Query with tax_query not working
- How to get all post_id and meta_value using meta_key in wp_postmeta table
- WP Query – Show custom posts only if user contain some user meta
- How do I subquery with custom meta fields?
- Showing Counts on Comment List with Custom Query