# Custom insertion order for new cards

**URL:** <https://forums.ankiweb.net/t/custom-insertion-order-for-new-cards/17470>\
**Category:** Suggestions\
**Created:** [February 9, 2022, 10:09am UTC](https://forums.ankiweb.net/t/custom-insertion-order-for-new-cards/17470 "2022-02-09T10:09:35Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jolarin](https://avatars.discourse-cdn.com/v4/letter/j/ea666f/32.png) [@Jolarin](https://forums.ankiweb.net/u/Jolarin)\
**Post date:** [February 9, 2022, 10:09am UTC](https://forums.ankiweb.net/t/custom-insertion-order-for-new-cards/17470/1 "2022-02-09T10:09:35Z")

</div>

I don’t think that, at the moment, there is a way to do this. If so, please let me know:

In my opinion, there are a lot of situations in which it is useful to see cards in a logical order when first learning them. This especially applies to complex topics like medicine, etc. For me, it helps introducing cards in a way, that depicts correlations between cards.  
Therefore, I think it would be really need to have the option of defining a insertion order for new cards. I picture a functionality in which you, in the browser, could drag and drop cards in a certain order, which would than be used as the order of new cards. This may be realised by a extra property for every card, which indicates the position in the respective sub-deck. That way, you could sort every subdeck on its own. Insertion of new cards would than follow the structure of “1. subdeck → 2. subdeck → …”, showing the cards of every subdeck in the given order.

I hope it was able to make clear, what I have in mind. I have no clue how complicated or impossible this might be, but I would love to see this feature in the future! 🙂

---

<div class="post-metadata">

**Author:** ![abdo](https://sea2.discourse-cdn.com/flex002/user_avatar/forums.ankiweb.net/abdo/32/654_2.png) [@abdo](https://forums.ankiweb.net/u/abdo)\
**Post date:** [February 9, 2022, 12:04pm UTC](https://forums.ankiweb.net/t/custom-insertion-order-for-new-cards/17470/2 "2022-02-09T12:04:08Z")

</div>

> [@Jolarin](#):
>
> This may be realised by a extra property for every card, which indicates the position in the respective sub-deck.

I guess Anki already has this (The “New #n” label shown in the due browser column)?  
You can use **Cards \> Reposition** to reorder cards, but that would be inconvenient if you want fine-tuned control.

Another option is to add a new sort field to your notes, something like “Position” that you can sort by in the browser and then use **Cards \> Reposition**.

---

<div class="post-metadata">

**Author:** ![Jolarin](https://avatars.discourse-cdn.com/v4/letter/j/ea666f/32.png) [@Jolarin](https://forums.ankiweb.net/u/Jolarin)\
**Post date:** [February 9, 2022, 4:46pm UTC](https://forums.ankiweb.net/t/custom-insertion-order-for-new-cards/17470/3 "2022-02-09T16:46:56Z")

</div>

That would be an (inconvenient) option for sorting your own cards one time before review.  
What I suggest implies a more “robust” method, which will also be useable with “forgeting cards” and exporting cards without scheduling information, in regards to sharing decks. The property therefore should be separate of the due status.  
The main usecase I have in mind is editing existing and adding new cards to an existing deck, bringing those cards in the right order and than beeing able to export those cards in that order for other people to use.

---

<div class="post-metadata">

**Author:** ![DoctorToBeIn23](https://avatars.discourse-cdn.com/v4/letter/d/e99b99/32.png) [@DoctorToBeIn23](https://forums.ankiweb.net/u/DoctorToBeIn23)\
**Post date:** [February 10, 2022, 4:12am UTC](https://forums.ankiweb.net/t/custom-insertion-order-for-new-cards/17470/4 "2022-02-10T04:12:11Z")

</div>

I use the duplicate and reorder add on, I duplicate the card where I want it inserted and then put the new text and info in.

---

<div class="post-metadata">

**Author:** ![Jolarin](https://avatars.discourse-cdn.com/v4/letter/j/ea666f/32.png) [@Jolarin](https://forums.ankiweb.net/u/Jolarin)\
**Post date:** [February 10, 2022, 9:50am UTC](https://forums.ankiweb.net/t/custom-insertion-order-for-new-cards/17470/5 "2022-02-10T09:50:42Z")

</div>

Thanks for sharing! This could be useful if you know the order of the cards when adding them. Never the less, creating all cards, bringing them in order and then duplicating them to “save” this order is quite laborious and would not work well with “updating addons” like CrowdAnki, as all cards would be treated as new after export.

---

<div class="post-metadata">

**Author:** ![dae](https://sea2.discourse-cdn.com/flex002/user_avatar/forums.ankiweb.net/dae/32/65_2.png) [@dae](https://forums.ankiweb.net/u/dae)\
**Post date:** [February 11, 2022, 6:29am UTC](https://forums.ankiweb.net/t/custom-insertion-order-for-new-cards/17470/6 "2022-02-11T06:29:17Z")

</div>

This is a known limitation, and will probably be fixed in the future.

> <https://github.com/ankitects/anki/issues/1658>
>
> Anki currently forgets the position/due# of a new card when it is reviewed for t…he first time. It would be nice to correct this, but as there is no column on the cards table set aside for this purpose, we need to decide where to store it, and consider the implications for syncing and compatibility with other clients/older Anki releases.
> 
> The simplest option would be to store the value in JSON in the \`data\` column of the cards table. It is not currently used, and was originally added with such extensibility purposes in mind. It is sent as a string in the current syncing protocol, and clients should be leaving it alone currently, so doing it this way should minimize compatibility issues.
> 
> JSON is not ideal for performance reasons though, as code like the deck list screen relies on a table scan of it performing relatively well, and the larger the table grows, the longer it takes to scan. We'd need to use something like the following in JSON:
> 
> {"pos":123456}
> 
> which is 14 bytes. If we instead were storing the value in a protobuf message in a blob, it would be 4 bytes.
> 
> But using protobuf at the moment will require changes to the sync protocol, and will likely break older clients if we start storing blob values in the cards table. So I think our only options at the moment are to hold off (which we've been doing for a long time already), or to go with JSON for now, and push a move to protobuf down the line (at the very least, we'll want to wait until AnkiDroid has caught up to the latest rslib).
